1. Field of the Invention
This invention relates generally to automatic margin adjusting systems, and more particularly to a high speed system for automatically adjusting line lengths of a textual code sequence stored in a memory before the entire sequence of codes is output from the memory to an output device.
2. Description of the Prior Art
A variety of systems are known in the prior art for providing some degree of right margin adjustment during the print-out of characters stored in a memory or bulk media. When a relatively small variation in line length has been desirable, a "hot zone" is usually established comprising a relatively small number of character print positions immediately preceding the desired maximum right margin. Depending on the prior art system, the first or last interword space code in the "hot zone" has been replaced by a line terminating code in the stored sequence of character and control codes corresponding to the printed text.
Prior art systems such as those described above generally include a printer that is operated during this right margin adjusting operation. An operator may be required during the margin adjusting operation to make occasional hyphenation decisions in instances wherein a word entirely spans the "hot zone" of a system that automatically inserts a line ending code only in the event that a space code or a hyphen code is found within the "hot zone". Although only occasional hyphenation decisions may be required, an operator, having no advance warning of when the hyphenation decisions will be required, must be present throughout the adjusting operation. This requires a large amount of operator time which, otherwise, may be wasted during the large proportion of print-out time during which no hyphenation decisions are necessary.
The publication "Preparing Media for Unattended Printing", IBM Technical Disclosure Bulletin Vol. 14, No. 7, page 2105 (December 1971) discloses a method of margin adjustment wherein the necessary revisions in the placement of line ending codes of text stored in a buffer are made during a revision pass of the text in the buffer during which hyphenation decisions are made and stored. The operator establishes a desired range of line lengths including a "hot zone". The text stored in the buffer is then scanned and only the words overlapping the "hot zone"and requiring hyphenation decisions are printed out. Since the scanning of the text in the buffer may be performed at a high speed that is not limited by the printer, a large amount of text may be adjusted in this manner in a relatively short time. Further, the time during which the buffer is scanned and during which line termination decisions are automatically made becomes relatively small compared to the time required for the printer to print words requiring a hyphenation decision and for the operator to make the decisions. Thus, relatively little time is wasted in having the operator present during the margin adjustment operation. No teaching is provided in the above publication, however, of providing an indication to the operator of the line number on which the word requiring a hyphenation decision occurs. A knowledge of the line number for each hyphenation decision would be useful to the operator, because it may be undesirable, for example, to hyphenate on two or more consecutive lines. In such instances, the operator may desire to include the entire word on one of the lines or move the entire word to the succeeding line.
Further, no teaching is included in this publication of providing an indication to the operator that the word requiring a hyphenation decision is the last word of a paragraph. An indication of this situation would be desirable to the operator, since it may be undesirable, from a grammatical standpoint, to hyphenate the last word of a paragraph.
Another example of a margin adjustment system that may be operated in a high speed mode is found in U.S. Pat. No. 3,772,655, entitled "Method of Obtaining Correspondence Between Memory and Output". In the system disclosed by this patent, line lengths may be adjusted during output of the character and control codes from a buffer memory to a bulk storage device. As in the above publication, however, no teaching is included in this patent of the provision of a line number indication with each hyphenation decision or the provision of an indication that a word requiring a hyphenation decision is the last word of a paragraph when such is the case.
Further in neither of these prior art references is there any teaching found regarding the handling, during an adjustment operation, of tab codes included in the sequence of text codes. When a printer is operated during margin adjustment, as in the systems first described above, the portion of the line length consumed by execution of the tab code can be determined from the printer for use in the adjustment procedure. Thus, for tabulation operations requiring increasingly longer portions of the line length, a smaller number of characters and spaces is combined with the tab code to form a line of the desired length. However, in systems wherein a tab code is not associated with a predetermined printer escapement, it would be necessary to provide a means for determining the proportion of the printed line length to be consumed by execution of the tab code if a high speed margin adjustment operation, not limited by relatively slow printer speed, is to be performed in the memory.
In the display system of U.S. Pat. No. 3,744,033, entitled, "Text Formatting for Display", an electronic tab rack comprising a random access memory is provided, having a bit storage position corresponding to each character position on the line to be displayed. Tabulation stops are electronically stored in selected character positions by setting the particular bits corresponding thereto. In this manner, a count can be made corresponding to the number of character positions between tabulation points. Space codes are input to the refresh buffer to fill blank spaces in lines in which tabulation operations are indicated. In storing and adjusting lines of text in a buffer to be printed, however, it would be inefficient to replace a single tab code with a varying plurality of space codes, according to the method of this patent, because valuable storage space would become unavailable for storage of text characters to be printed.
It would, therefore, be advantageous to provide a system for automatically performing a high speed arrangement of stored textual character codes and control codes, including tab codes, thereby providing line lengths within a predetermined range. When hyphenation decisions are required, it would be advantageous to provide an operator readable indication of the line number on which the decision must be made and an indication of whether or not the word involved is the last word in a paragraph.